/*
 * @Descripttion: miam.js
 * @Author: 银河以北
 * @Date: 2021-09-17 20:52:13
 * @LastEditors: 银河以北
 * @LastEditTime: 2021-11-14 21:20:15
 */
import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import '@/router/permission'

//给vuex设置token
import { getToken } from '@/utils/auth'
store.commit('SET_TOKEN', getToken())


//引入md5加密方式
import md5 from 'js-md5';

//引入自己的图片处理方式
import { imgUrl } from '@/utils/utils'

//全局样式
// import '@/style/index.scss'
// import '@/style/minxin.scss'
// import '@/style/base.scss'


//创建vue对象
const app = createApp(App)

//挂载vuex
app.use(store)

//挂载路由
app.use(router)

//挂载ElementPlus
app.use(ElementPlus)

//挂载全局通用方法
app.config.globalProperties.$utils = {
    md5,
    imgUrl
}
app.mount('#app')
